Skip to content

iterator: Add IteratorUtil::max_by/min_by method #7414

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

iterator: Add IteratorUtil::max_by/min_by method #7414

wants to merge 1 commit into from

Conversation

gifnksm
Copy link
Contributor

@gifnksm gifnksm commented Jun 26, 2013

max_by method returns the element that gives the maximum value from the specfied function.
max_by/min_by are convenient when you want to get the value which has greatest/smallest scores.

Inspired by ruby's Enumerable module.

bors added a commit that referenced this pull request Jun 27, 2013
`max_by` method returns the element that gives the maximum value from the specfied function.
`max_by`/`min_by` are convenient when you want to get the value which has greatest/smallest scores.

Inspired by [ruby's Enumerable module](http://ruby-doc.org/core-2.0/Enumerable.html).
@bors bors closed this Jun 27, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants